From: Adam Williamson Date: Sat, 25 Mar 2023 16:19:41 +0000 (-0700) Subject: screenshot: Fix broken GLib.Error.matches call X-Git-Tag: archive/raspbian/50.5-1+rpi1~1^2~371^2^2~70 X-Git-Url: https://dgit.raspbian.org/%22http://www.example.com/cgi/%22/%22http:/www.example.com/cgi/%22?a=commitdiff_plain;h=a093a721fa7942e378d7caaa15f8f111ecafedc7;p=gnome-shell.git screenshot: Fix broken GLib.Error.matches call You have to pass a domain and an error code, not just an error code. Fixes https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/6540 Signed-off-by: Adam Williamson Part-of: --- diff --git a/js/ui/screenshot.js b/js/ui/screenshot.js index ecbe50bcc..d25744e87 100644 --- a/js/ui/screenshot.js +++ b/js/ui/screenshot.js @@ -2084,7 +2084,7 @@ function _storeScreenshot(bytes, pixbuf) { try { bookmarks.load_from_file(recentFile); } catch (e) { - if (!e.matches(GLib.BookmarkFileError.FILE_NOT_FOUND)) { + if (!e.matches(GLib.BookmarkFileError, GLib.BookmarkFileError.FILE_NOT_FOUND)) { log(`Could not open recent file ${uri}: ${e.message}`); return; }